<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <div>
        <div id="app">
            <!-- 完整写法： -->
            <!-- <button v-on:click="show">点我弹框</button> -->
            <!-- 简写用法： -->
            <button @click="show">点我弹框</button>
        </div>
    </div>
    <script src="../assets/vue2.js"></script>
    <script>
        const app = new Vue({
            el: '#app',
            methods: {
                show() {
                    alert('v-on test');
                }
            },
        });
    </script>
</body>

</html>